<template >
    <a-button size="small"  @click="viewTotal()" v-auth="props.auth">查看统计</a-button>              
    <total-modal ref="totalModalRef" />
</template>

<script setup lang="jsx">
import {ref} from "vue";
import TotalModal from "@cps/actionsNew/totalModal.vue";
const totalModalRef = ref()
const props = defineProps({
    auth: {
        type: Array,
        default: []
    },
    api: {
        type: Function,
        default: ()=>{}
    },
})
const viewTotal = () =>{
  totalModalRef.value.show('查看统计',props.api)
}
</script>